import request from '@/utils/request'

// 查询库存商品列表
export function listTableStock(query) {
  return request({
    url: '/stocktb/stocktb/list',
    method: 'get',
    params: query
  })
}

// 查询库存商品详细
export function getTableStock(warehouseStockTbId) {
  return request({
    url: '/stocktb/stocktb/' + warehouseStockTbId,
    method: 'get'
  })
}

// 新增库存商品
export function addTableStock(data) {
  return request({
    url: '/stocktb/stocktb',
    method: 'post',
    data: data
  })
}

// 修改库存商品
export function updateTableStock(data) {
  return request({
    url: '/stocktb/stocktb',
    method: 'put',
    data: data
  })
}

// 删除库存商品
export function delTableStock(warehouseStockTbId) {
  return request({
    url: '/stocktb/stocktb/' + warehouseStockTbId,
    method: 'delete'
  })
}
